package com.yqz.sys.form;

import com.yqz.common.base.Form;
import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.NotEmpty;

import javax.validation.constraints.NotNull;
import java.util.Date;

public class CompUserForm extends Form {
    /**
     * 用户id
     */
    private Integer id;
    /**
     * 手机号
     */
    @NotEmpty(message = "手机号不可为空")
    @Length(min = 11,max = 11,message = "手机号只能为11位")
    private String phone;
    /**
     * 密码
     */
    @NotEmpty(message = "密码不能为空")
    @Length(max = 25,message = "密码最多只能为25位")
    private String password;
    /**
     * 姓名
     */
    @NotEmpty(message = "姓名不能为空")
    @Length(max = 25,message = "姓名最多为20位")
    private String name;
    /**
     * 生日
     */
    @NotEmpty(message = "生日不能为空")
    private String birth;
    /**
     * 头像
     */
    private String img;
    /**
     * 公司id
     */
    private Integer compId;
    /**
     * 部门id
     */
    @NotNull(message = "部门不可为空")
    private Integer deptId;
    /**
     * 1 在职 2 离职
     */
    private Integer flag;
    /**
     * 创建时间
     */
    private Date createTime;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getBirth() {
        return birth;
    }

    public void setBirth(String birth) {
        this.birth = birth;
    }

    public String getImg() {
        return img;
    }

    public void setImg(String img) {
        this.img = img;
    }

    public Integer getFlag() {
        return flag;
    }

    public void setFlag(Integer flag) {
        this.flag = flag;
    }

    public Integer getCompId() {
        return compId;
    }

    public void setCompId(Integer compId) {
        this.compId = compId;
    }

    public Integer getDeptId() {
        return deptId;
    }

    public void setDeptId(Integer deptId) {
        this.deptId = deptId;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
}
